package edu.xust.web.controller;

import edu.xust.config.*;
import edu.xust.dto.BaseDto;
import edu.xust.page.PageInfo;
import edu.xust.service.TStudentService;

/**
 * 学生类的控制器 门卫 对url的响应处理
 */
@Controller("/tstudentController")
public class TStudentController {
    @Resource
    TStudentService tStudentService;


    @RequestMapping("/selectTStudentByPage")
    @ResponseBody
    public BaseDto selectTStudentByPage(@RequestBody PageInfo pageInfo) throws Exception {/*@RequestBody PageInfo pageInfo*/

        /*pageInfo.setCurrPage(currPage);
        pageInfo.setPageSize(pageSize);*/

        BaseDto tStudentByPage = tStudentService.getTStudentByPage(pageInfo);
//        System.out.println(tStudentByPage);

        return  tStudentByPage;
    }


    @RequestMapping("/selectTStudentByPageOftwo")
    @ResponseBody
    public BaseDto selectTStudentByPageOftwo(@RequestBody PageInfo pageInfo) throws Exception {/*@RequestBody PageInfo pageInfo*/
        BaseDto tStudentByPage = tStudentService.getTStudentByPage(pageInfo);
        return  tStudentByPage;
    }




    }

